import { createStore, applyMiddleware } from 'redux'
import { composeWithDevTools } from 'redux-devtools-extension'
import reducer from './reducer'
import thunk from 'redux-thunk'
// 2. 创建store对象
const store = createStore(
  reducer,
  //   { count: 8 }, // 可以用来初始化redux数据，优先级更高。 但是不常用
  composeWithDevTools(applyMiddleware(thunk))
)
export default store
